package com.xyauto.test.activity;

import android.content.Context;
import android.graphics.Color;
import android.os.Bundle;
import android.util.Log;

import androidx.appcompat.app.AppCompatActivity;
import androidx.core.graphics.ColorUtils;

import com.xyauto.test.R;
import com.xyauto.uilibx.colorpicker.BitmapColorHelper;
import com.xyauto.uilibx.colorpicker.IBitmapColorProvider;
import com.xyauto.uilibx.utils.ColorUtil;


public class MainActivity extends AppCompatActivity {


    private static final String TAG = "TestActivity";

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        BitmapColorHelper.getInstance().setColorProvider((colors, gradientSize, layerSize) -> {
            colors[0] = Color.RED;
            colors[1] = ColorUtil.colorDeviation(Color.RED, 255);
            colors[2] = Color.BLUE;
            colors[3] = ColorUtil.colorDeviation(Color.BLUE, 50);
        });
        setContentView(R.layout.activity_main);

    }

}